home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
TPUG - Toronto PET Users Group
/
TPUG Users Group CD
/
TPUG Users Group CD.iso
/
C64
/
E-Education
/
(c)ed14.d64
/
lesson 7
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2007-02-04
|
8KB
|
225 lines
10 GOTO100
50 REM <YES>
51 S=54272:FORE=STOS+28:POKEE,0:NEXT
52 POKE54296,15:POKE54277,42:POKE54278,250
53 POKE54276,23:POKE54273,23:POKE54272,191
54 FORT=1TO150:NEXT:POKE54276,32:FORT=1TO200:NEXT
55 POKE54296,0:RETURN
60 REM <N0>
61 S=54272:FORE=STOS+28:POKEE,0:NEXT
62 POKE54296,15:POKE54277,18:POKE54278,242
63 POKE54276,33:POKE54273,4:POKE54272,48
64 FORT=1TO250:NEXT:POKE54276,32:FORT=1TO300:NEXT
65 POKE54296,0:RETURN
70 REM <BLIP>
71 S=54272:FORE=STOS+28:POKEE,0:NEXT
72 POKE54296,5:POKE54277,42:POKE54278,250
73 POKE54276,23:POKE54273,23:POKE54272,191
74 FORT=1TO30:NEXT:POKE54276,32:FORT=1TO50:NEXT
75 POKE54296,0:RETURN
80 FORT=1TO500:NEXT:RETURN
81 FORT=1TO1000:NEXT:RETURN
82 FORT=1TO2000:NEXT:RETURN
83 FORT=1TO3000:NEXT:RETURN
84 FORT=1TO4000:NEXT:RETURN
85 FORT=1TO5000:NEXT:RETURN
90 GOSUB81:GOSUB70
91 PRINT"[154] [208]RESS [211][208][193][195][197][160][194][193][210][160]TO CONTINUE
92 [161]R$:[139]R$[179][177][199](32)[167]92
93 [142]
95 [153]" PEEKETTER LUCK WITH THE NEXT QUESTION.OPEN":[142]
100 [151]53280,0:[151]53281,0:[151]646,3:[151]53272,23:C[178]0:P[178]0:W[178]0:D[178]0:G[178]0
101 [153]"LOAD ATNCLOSE(null)(null)(null)CHR$CLOSEVALSTR$(null)LENATN(null)RIGHT$(null)(null)ATN(null)CLOSE(null)(null)(null)CHR$(null)ATN(null)
102 PRINT" [198][207][210][160][195]64 [195][207][205][208][213][212][197][210][211]
105 [153]" WAIT";
110 [153]" WAIT";
115 [153]" (null)RACTICE (null)ROBLEMS IN ATNRITHMETIC WAIT";
120 [153]" WAIT";
125 [153]" CHR$RADE 4 (null)ART 1 WAIT";
130 [153]" WAIT";
135 [153]" (null)ESSON 7 WAIT";
140 [153]" WAIT";
145 [153]" ASCINDING STR$IFFERENCES OPEN WAIT";
150 [153]" WAIT";
155 [153]" WAIT"
160 [153]" WHC ONON"
165 [141]90
170 [153]"LOAD ATNND AWAY WE GO......."
175 [141]81:[141]50:[141]80
200 [153]"PRINT#LOAD (null)UESTION 1 WAITOPEN":Z[178]0
205 [153]" MID$OHN IS 9 YEARS OLD AND HIS COUSIN
210 PRINT" IS 5 YEARS OLDER.
215 [153]" LEFT$OW OLD IS MID$OHN'S COUSIN?OPEN"
220 [141]81:[141]70
225 [153]" ON"
230 [133] A$
240 [139]A$[179][177]"14"[175]A$[179][177]"14 YEARS"[167] 270
250 [153]"SYS LEN(null)(null)(null)VALLEN(null)!! WAITOPEN":[141]50:[141]82
260 P[178]P[170]1:[137]300
270 [153]"DEF (null)(null)LENLEFT$! .......... (null)HAT LEFT$(null)(null)(null)!":[141]60:[141]82:Z[178]Z[170]1
275 [139]Z[178]2[167]G[178]G[170]1:[137]295
280 [153]"ON (null)RY AGAIN ":[141]70:[141]81:W[178]W[170]1
290 [153]"OPENONON ONONONONONONON":[137]225
295 [153]"ONON MID$OHN'S COUSIN IS 14DEF. ":[141]82
297 [153]" 9 + 5 = 14 ":[141]82:[141]90
300 [153]"PRINT#LOAD (null)UESTION 2 WAITOPEN":Z[178]0
305 [153]" (null)OM SOLD 18 NEWSPAPERS ON ASCRIDAY AND
310 PRINT" 32 ON [211]ATURDAY.
315 [153]" LEFT$OW MANY MORE DID HE SELL ON (null)ATURDAY THAN ON ASCRIDAY.OPEN
320 GOSUB81:GOSUB70
325 PRINT" [145]"
330 INPUT A$
340 IFA$<>"14"THEN 370
350 PRINT"[158] [195][207][210][210][197][195][212]!! [146][159]":GOSUB50:GOSUB82
360 P=P+1:GOTO400
370 PRINT"[150] [207][213][195][200]! .......... [212]HAT [200][213][210][212]!":GOSUB60:GOSUB82:Z=Z+1
375 IFZ=2 THEN G=G+1:GOTO395
380 PRINT"[145] [212]RY AGAIN ":GOSUB70:GOSUB81:W=W+1
390 PRINT"[159][145][145] [145][145][145][145][145][145][145]":GOTO325
395 PRINT"[145][145] [200]E SOLD 14[150] MORE PAPERS. ":GOSUB82
397 PRINT" 32 - 18 = 14 ":GOSUB82:GOSUB90
400 PRINT"[152][147] [209]UESTION 3 [146][159]":Z=0
405 PRINT" [202]AMIE PAID 75 CENTS FOR A CAP AND
410 [153]" CHR$ILLIAN SPENT 90 CENTS FOR A DOLL
415 PRINT" [200]OW MUCH MORE DID [199]ILLIAN SPEND THAN [202]AMIE?[159]"
420 GOSUB81:GOSUB70
425 PRINT" [145]"
430 INPUT A$
440 IFA$<>"15"ANDA$<>"15 CENTS"THEN470
450 PRINT"[158] [195][207][210][210][197][195][212]!! [146][159]":GOSUB50:GOSUB82
460 P=P+1:GOTO500
470 PRINT"[150] [207][213][195][200]! .......... [212]HAT [200][213][210][212]!":GOSUB60:GOSUB82:Z=Z+1
475 IFZ=2THENG=G+1:GOTO495
480 PRINT"[145] [212]RY AGAIN ":GOSUB70:GOSUB81:W=W+1
490 PRINT"[159][145][145] [145][145][145][145][145][145][145]":GOTO425
495 PRINT"[145][145] [199]ILLIAN SPENT 15[150] CENTS MORE. ":GOSUB82
497 PRINT" 90 - 75 = 15 ":GOSUB82:GOSUB90
500 PRINT"[152][147] [209]UESTION 4 [146][159]":Z=0
505 PRINT" [207]N AN CAR TRIP LAST WEEK [212]ED RODE 56
510 [153]" KILOMETRES. PEEKETTY ALSO MADE A TRIP OF 72 KILOMETRES.
515 PRINT" [200]OW MUCH FARTHER DID [194]ETTY RIDE THAN [212]ED?[159] (IN KM)"
520 GOSUB81:GOSUB70
525 PRINT" [145]"
530 INPUT A$
540 IFA$<>"16KM"ANDA$<>"16 KM"THEN 570
550 PRINT"[158] [195][207][210][210][197][195][212]!! [146][159]":GOSUB50:GOSUB82
560 P=P+1:GOTO600
570 PRINT"[150] [207][213][195][200]! .......... [212]HAT [200][213][210][212]!":GOSUB60:GOSUB82:Z=Z+1
575 IFZ=2THENG=G+1:GOTO595
580 PRINT"[145] [212]RY AGAIN ":GOSUB70:GOSUB81:W=W+1
590 PRINT"[159][145][145] [145][145][145][145][145][145][145]":GOTO525
595 PRINT"[145][145] [194]ETTY RODE 16[150]KM FARTHER. ":GOSUB82
597 PRINT" 72 - 56 = 16 ":GOSUB82:GOSUB90
600 PRINT"[152][147] [209]UESTION 6 [146][159]":Z=0
605 PRINT" [200]OW MANY MORE DAYS ARE THERE IN
610 [153]" MID$ANUARY THAN ASCEBRUARY? ((null)(null)(null) A (null)EAP (null)EAR)"
620 [141]81:[141]70
625 [153]" ON"
630 [133] A$
640 [139]A$[179][177]"3"[167] 670
650 [153]"SYS LEN(null)(null)(null)VALLEN(null)!! WAITOPEN":[141]50:[141]82
660 P[178]P[170]1:[137]700
670 [153]"DEF (null)(null)LENLEFT$! .......... (null)HAT LEFT$(null)(null)(null)!":[141]60:[141]82:Z[178]Z[170]1
675 [139]Z[178]2[167]G[178]G[170]1:[137]695
680 [153]"ON (null)RY AGAIN ":[141]70:[141]81:W[178]W[170]1
690 [153]"OPENONON ONONONONONONON":[137]625
695 [153]"ONON MID$ANUARY WOULD HAVE 3DEF DAYS MORE. ":[141]82
697 [153]" 31 - 28 = 3 ":[141]82:[141]90
700 [153]"PRINT#LOAD (null)UESTION 6 WAITOPEN":Z[178]0
705 [153]" ATN FARMER RAISED 97 TONS OF WHEAT
710 PRINT" AND 62 TONS OF CORN.
715 [153]" LEFT$OW MUCH MORE WHEAT DID HE RAISE THAN CORN?OPEN"
720 [141]81:[141]70
725 [153]" ON"
730 [133] A$
740 [139]A$[179][177]"35"[175]A$[179][177]"35 TONS"[167] 770
750 [153]"SYS LEN(null)(null)(null)VALLEN(null)!! WAITOPEN":[141]50:[141]82
760 P[178]P[170]1:[137]800
770 [153]"DEF (null)(null)LENLEFT$! .......... (null)HAT LEFT$(null)(null)(null)!":[141]60:[141]82:Z[178]Z[170]1
775 [139]Z[178]2[167] G[178]G[170]1:[137]795
780 [153]"ON (null)RY AGAIN ":[141]70:[141]81:W[178]W[170]1
790 [153]"OPENONON ONONONONONONON":[137]725
795 [153]"ONON LEFT$E RAISED 35DEF MORE TONS OF WHEAT.":[141]82
797 [153]" 97 - 62 = 35 ":[141]82:[141]90
800 [153]"PRINT#LOAD (null)UESTION 7 WAITOPEN":Z[178]0
805 [153]" LEFT$OW MUCH HEAVIER IS (null)ARY WHO WEIGHS
810 PRINT" 24KG THAN [211]ARAH WHO WEIGHS JUST 16KG? (IN KG) "
820 GOSUB81:GOSUB70
825 PRINT" [145]"
830 INPUT A$
840 IFA$<>"8KG"ANDA$<>"8 KG"THEN 870
850 PRINT"[158] [195][207][210][210][197][195][212]!! [146][159]":GOSUB50:GOSUB82
860 P=P+1:GOTO900
870 PRINT"[150] [207][213][195][200]! .......... [212]HAT [200][213][210][212]!":GOSUB60:GOSUB82:Z=Z+1
875 IFZ=2THEN G=G+1:GOTO895
880 PRINT"[145] [212]RY AGAIN ":GOSUB70:GOSUB81:W=W+1
890 PRINT"[159][145][145] [145][145][145][145][145][145][145]":GOTO825
895 PRINT"[145][145] [205]ARY IS 8[150]KG HEAVIER. ":GOSUB82
897 PRINT" 24 - 16 = 8 ":GOSUB82:GOSUB90
900 PRINT"[152][147] [209]UESTION 8 [146][159]":Z=0
905 PRINT" [198]OR A CHURCH FAIR [193]NNE MADE 19 APRONS
910 [153]" AND MID$ULIA MADE 12.
915 PRINT" [200]OW MANY MORE APRONS DID [193]NNE MAKE THAN [202]ULIA?[159]"
920 GOSUB81:GOSUB70
925 PRINT" [145]"
930 INPUT A$
940 IFA$<>"7"THEN 970
950 PRINT"[158] [195][207][210][210][197][195][212]!! [146][159]":GOSUB50:GOSUB82
960 P=P+1:GOTO1000
970 PRINT"[150] [207][213][195][200]! .......... [212]HAT [200][213][210][212]!":GOSUB60:GOSUB82:Z=Z+1
975 IFZ=2THEN G=G+1:GOTO995
980 PRINT"[145] [212]RY AGAIN ":GOSUB70:GOSUB81:W=W+1
990 PRINT"[159][145][145] [145][145][145][145][145][145][145]":GOTO925
995 PRINT"[145][145] [193]NNE MADE 7[150] MORE APRONS. ":GOSUB82
997 PRINT" 19 - 12 = 7 ":GOSUB82:GOSUB90
1000 PRINT"[152][147] [209]UESTION 9 [146][159]":Z=0
1005 PRINT" [212]HERE ARE 27 GIRLS AND 19 BOYS IN THE CLASSROOM.
1015 [153]" LEFT$OW MANY MORE GIRLS THAN BOYS ARE THERE?OPEN"
1020 [141]81:[141]70
1025 [153]" ON"
1030 [133] A$
1040 [139]A$[179][177]"8"[175]A$[179][177]"8 GIRLS"[167] 1070
1050 [153]"SYS LEN(null)(null)(null)VALLEN(null)!! WAITOPEN":[141]50:[141]82
1060 P[178]P[170]1:[137]1100
1070 [153]"DEF (null)(null)LENLEFT$! .......... (null)HAT LEFT$(null)(null)(null)!":[141]60:[141]82:Z[178]Z[170]1
1075 [139]Z[178]2[167] G[178]G[170]1:[137]1095
1080 [153]"ON (null)RY AGAIN ":[141]70:[141]81:W[178]W[170]1
1090 [153]"OPENONON ONONONONONONON":[137]1025
1095 [153]"ONON (null)HERE ARE 8DEF MORE GIRLS. ":[141]82
1097 [153]" 27 - 19 = 8 ":[141]82:[141]90
1100 [153]"PRINT#LOAD (null)UESTION 10 WAITOPEN":Z[178]0
1105 [153]" RIGHT$N THE SCHOOL YARD THE MAPLE TREE
1110 PRINT" IS 19 METRES HIGH AND THE APPLE TREE IS 6 METRES HIGH.
1115 [153]" LEFT$OW MUCH HIGHER IS THE MAPLE TREE?OPEN (IN M) "
1120 [141]81:[141]70
1125 [153]" ON"
1130 [133] A$
1140 [139]A$[179][177]"13M"[175]A$[179][177]"13 M"[167] 1170
1150 [153]"SYS LEN(null)(null)(null)VALLEN(null)!! WAITOPEN":[141]50:[141]82
1160 [137]1200
1170 [153]"DEF (null)(null)LENLEFT$! .......... (null)HAT LEFT$(null)(null)(null)!":[141]60:[141]82:Z[178]Z[170]1
1175 [139]Z[178]2[167] G[178]G[170]1:[137]1195
1180 [153]"ON (null)RY AGAIN ":[141]70:[141]81:W[178]W[170]1
1190 [153]"OPENONON ONONONONONONON":[137]1125
1195 [153]"ONON (null)HE MAPLE TREE IS 13MDEF HIGHER. ":[141]82
1197 [153]" 19 - 6 = 13 ":[141]82:[141]90
1200 [153]"LOAD (null)EPORT LENARD WAIT"
1205 D[178]W[171]G:C[178]10[171]W
1210 [153]"PRINT 1. (null)UESTIONS ANSWERED CORRECTLY ON FIRST TRY:
1215 PRINT" ";C
1220 PRINT"[129] 2. [209]UESTIONS ANSWERED CORRECTLY ON SECOND TRY:
1225 [153]" ";D
1230 [153]"DEF 3. (null)UESTIONS MISSED ON SECOND TRY:
1235 PRINT" ";G;""
1245 GOSUB90
1250 PRINT"[158][147] [217]OU HAVE A CHOICE:
1255 [153]" (null)RESS (null) WAIT TO REPEAT THIS LESSON
1260 PRINT" [208]RESS [205] [146] TO RETURN TO THE MENU[159]"
1265 GETR$:IFR$<>"R"ANDR$<>"M"THEN1265
1270 IFR$="R"THENRESTORE:GOTO100
1280 PRINT"[147] [210]ETURNING TO THE MENU
1285 [147]"MENU",8
1290 [138]
1295 [128]
1300 [143] BILL CUMBERLAND 90:10:25